load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
load("//bazel:skia_rules.bzl", "exports_files_legacy")

licenses(["notice"])

exports_files_legacy()

go_library(
    name = "perf_puppeteer_canvas_lib",
    srcs = ["perf_puppeteer_canvas.go"],
    importpath = "go.skia.org/skia/infra/bots/task_drivers/perf_puppeteer_canvas",
    visibility = ["//visibility:private"],
    deps = [
        "@org_skia_go_infra//go/exec",
        "@org_skia_go_infra//go/skerr",
        "@org_skia_go_infra//task_driver/go/lib/os_steps",
        "@org_skia_go_infra//task_driver/go/td",
    ],
)

go_binary(
    name = "perf_puppeteer_canvas",
    embed = [":perf_puppeteer_canvas_lib"],
    visibility = ["//visibility:public"],
)

go_test(
    name = "perf_puppeteer_canvas_test",
    srcs = ["perf_puppeteer_canvas_test.go"],
    embed = [":perf_puppeteer_canvas_lib"],
    deps = [
        "@com_github_stretchr_testify//assert",
        "@com_github_stretchr_testify//require",
        "@org_skia_go_infra//go/exec",
        "@org_skia_go_infra//go/testutils",
        "@org_skia_go_infra//task_driver/go/td",
    ],
)
